import * as types from '../actionsType/login'

const initState = ''

const login = (state = initState, action) => {
   switch(action.type) {
    case types.GET_TOKEN: 
      return action.payload
    case types.CLEAR_TOKEN:
      return initState
    default:
      return state
   }
}

export default login